package cn.com.headfree.vo.simple;

import com.deepoove.poi.data.DocxRenderData;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang.StringUtils;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;

/**
 * 导师带徒,根据导师的erp_no查询
 */
public class SdtTutorPrentInfoVo {

    private static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");

    /**
     * 师带徒id
     */
    private String id;

    /**
     * 师带徒开始时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date startDate;

    private String startDateStr;

    /**
     * 师带徒结束时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date endDate;

    private String endDateStr;

    /**
     * 导师姓名
     */
    private String tutorName;
    /**
     * 徒弟姓名
     */
    private String prentName;
    /**
     * 师带徒内容摘要
     */
    private String teachSummary;
    /**
     * 导师erpno
     */
    private String erpNo;
    /**
     * 导师身份证号
     */
    private String idCardNo;
    /**
     * 创建者id
     */
    private String createrId;
    /**
     * 创建者姓名
     */
    private String createrName;
    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date createTime;
    /**
     * 更新者id
     */
    private String updaterId;
    /**
     * 更新者姓名
     */
    private String updaterName;
    /**
     * 更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date updateTime;
    /**
     * 0:未删除1：已删除
     */
    private Integer delSign;
    /**
     * 是否有效数据(0:有效，1:无效)
     */
    private Integer isValid;
    /**
     * 审核状态
     */
    private Integer auditState;

    /**
     * 徒弟erp编号,从徒弟表中获取
     */
    private String prentErpNo;

    /**
     * 徒弟所获奖项,从徒弟表中获取
     */
    private String prentAwardName;

    /**
     * 徒弟奖项id
     */
    private String awardId;

    private String userName;

    private List<SdtPrentInfoVo> sdtPrentInfos;

    private DocxRenderData sdtPrentsEx;

    public DocxRenderData getSdtPrentsEx() {
        return sdtPrentsEx;
    }

    public void setSdtPrentsEx(DocxRenderData sdtPrentsEx) {
        this.sdtPrentsEx = sdtPrentsEx;
    }

    public List<SdtPrentInfoVo> getSdtPrentInfos() {
        return sdtPrentInfos;
    }

    public void setSdtPrentInfos(List<SdtPrentInfoVo> sdtPrentInfos) {
        this.sdtPrentInfos = sdtPrentInfos;
    }

    public String getStartDateStr() {
        return startDateStr;
    }

    public void setStartDateStr(String startDateStr) {
        if (StringUtils.isNotBlank(startDateStr)) {
            this.startDateStr = startDateStr.split(" ")[0];
        } else {
            this.startDateStr = startDateStr;
        }
    }

    public String getEndDateStr() {
        return endDateStr;
    }

    public void setEndDateStr(String endDateStr) {
        if (StringUtils.isNotBlank(endDateStr)) {
            this.endDateStr = endDateStr.split(" ")[0];
        } else {
            this.endDateStr = endDateStr;
        }
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getAwardId() {
        return awardId;
    }

    public void setAwardId(String awardId) {
        this.awardId = awardId;
    }

    public Date getStartDate() {
        return startDate;
    }

    public void setStartDate(Date startDate) {
        this.startDate = startDate;
        if (startDate!=null){
            this.startDateStr=sdf.format(startDate).split(" ")[0];
        }
    }

    public Date getEndDate() {
        return endDate;
    }

    public void setEndDate(Date endDate) {
        this.endDate = endDate;
        if (endDate!=null){
            this.endDateStr=sdf.format(endDate).split(" ")[0];
        }
    }

    public String getTutorName() {
        return tutorName;
    }

    public void setTutorName(String tutorName) {
        this.tutorName = tutorName;
    }

    public String getPrentName() {
        return prentName;
    }

    public void setPrentName(String prentName) {
        this.prentName = prentName;
    }

    public String getTeachSummary() {
        return teachSummary;
    }

    public void setTeachSummary(String teachSummary) {
        this.teachSummary = teachSummary;
    }

    public String getErpNo() {
        return erpNo;
    }

    public void setErpNo(String erpNo) {
        this.erpNo = erpNo;
    }

    public String getIdCardNo() {
        return idCardNo;
    }

    public void setIdCardNo(String idCardNo) {
        this.idCardNo = idCardNo;
    }

    public String getCreaterId() {
        return createrId;
    }

    public void setCreaterId(String createrId) {
        this.createrId = createrId;
    }

    public String getCreaterName() {
        return createrName;
    }

    public void setCreaterName(String createrName) {
        this.createrName = createrName;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getUpdaterId() {
        return updaterId;
    }

    public void setUpdaterId(String updaterId) {
        this.updaterId = updaterId;
    }

    public String getUpdaterName() {
        return updaterName;
    }

    public void setUpdaterName(String updaterName) {
        this.updaterName = updaterName;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public Integer getDelSign() {
        return delSign;
    }

    public void setDelSign(Integer delSign) {
        this.delSign = delSign;
    }

    public Integer getIsValid() {
        return isValid;
    }

    public void setIsValid(Integer isValid) {
        this.isValid = isValid;
    }

    public Integer getAuditState() {
        return auditState;
    }

    public void setAuditState(Integer auditState) {
        this.auditState = auditState;
    }

    public String getPrentErpNo() {
        return prentErpNo;
    }

    public void setPrentErpNo(String prentErpNo) {
        this.prentErpNo = prentErpNo;
    }

    public String getPrentAwardName() {
        return prentAwardName;
    }

    public void setPrentAwardName(String prentAwardName) {
        this.prentAwardName = prentAwardName;
    }
}
